{% if paginator_page_count > 0 %}
<div class="pager">
    {% if paginator_page_count > 1 %}
        <ul class="navigation">
            <li><a href="{{ ln_query_string("page", 1)}}"><<</a></li>

            {% if paginator_current_page == 1 %}
            <li><a href="{{ ln_query_string("page", paginator_page_count)}}"><</a></li>
            {% else %}
            <li><a href="{{ ln_query_string("page", paginator_current_page-1)}}"><</a></li>
            {% endif %}

            {% for page in 1..paginator_page_count %}
                {% if page == paginator_current_page %}
                <li class="selected">[{{page}}]</li>
                {% else %}
                <li><a href="{{ ln_query_string("page", page)}}">{{page}}</a></li>
                {% endif %}
            {% endfor %}

            {% if paginator_current_page < paginator_page_count %}
            <li><a href="{{ ln_query_string("page", paginator_current_page+1)}}">></a></li>
            {% else %}
            <li><a href="{{ ln_query_string("page", 1)}}">></a></li>
            {% endif %}

            <li><a href="{{ ln_query_string("page", paginator_page_count)}}">>></a></li>
        </ul>
    {% endif %}

    <ul class="options">
        {% for leap in paginator_per_page_leap %}
            {% if paginator_per_page == leap %}
            <li class="selected">[{{leap}}]</li>
            {% else %}
            <li><a href="{{ ln_query_string("per_page", leap)}}">{{leap}}</a></li>
            {% endif %}
        {% endfor %}
    </ul>
</div>
{% endif %}